package com.heima.feign.article;

import com.heima.feign.fallback.IArticleClientFallback;
import com.heima.model.article.dtos.ArticleDto;
import com.heima.model.common.dtos.ResponseResult;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;

/**
 * @Author: JW
 * @Description: TODO
 * @DateTime: 2022-02-13 20:16
 **/
@FeignClient(value = "leadnews-article",fallback = IArticleClientFallback.class)
public interface IArticleClient {


    /**
     * @Author: JW
     * @Description:  TODO 保存文章
     * @Date: 20:19 2022-02-13
     * @Param: [articleDto]
     * @return: com.heima.model.common.dtos.ResponseResult
    **/
    @PostMapping("/api/v1/article/save")
    ResponseResult saveArticle(@RequestBody ArticleDto articleDto);
}
